package light.head.model;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 *	企业活动(公告 ，公司动态)
 */
@Entity
@Table
public class OrganActivities implements Serializable{
	private static final long serialVersionUID = -8621297109150581834L;
	private Integer code;				//流水号
	private Integer oc;					//公司编号
	private String title;				//标题
	private String content;				//内容
	private Byte type;					//类型(0.公告 1.公司动态)
	private Integer cu;					//穿件人
	private Date ct;					//创建时间
	private Date pt;					//发布时间
	private Date topTime;				//置顶时间
	private boolean deleted;			//是否删除
	
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column
	public Integer getCode() {
		return code;
	}
	@Column(updatable = false)
	public Integer getOc() {
		return oc;
	}
	@Column(length = 300)
	public String getTitle() {
		return title;
	}
	@Column(length = 10000)
	public String getContent() {
		return content;
	}
	@Column
	public Byte getType() {
		return type;
	}
	@Column
	public Integer getCu() {
		return cu;
	}
	@Temporal(TemporalType.TIMESTAMP)
	@Column(updatable = false, nullable = false)
	public Date getCt() {
		return ct;
	}
	@Temporal(TemporalType.TIMESTAMP)
	@Column
	public Date getPt() {
		return pt;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column
	public Date getTopTime() {
		return topTime;
	}
	@Column
	public boolean isDeleted() {
		return deleted;
	}
	
	public void setCode(Integer code) {
		this.code = code;
	}
	public void setOc(Integer oc) {
		this.oc = oc;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	public void setContent(String content) {
		this.content = content;
	}
	public void setCu(Integer cu) {
		this.cu = cu;
	}
	public void setCt(Date ct) {
		this.ct = ct;
	}
	public void setPt(Date pt) {
		this.pt = pt;
	}
	public void setType(Byte type) {
		this.type = type;
	}
	public void setTopTime(Date topTime) {
		this.topTime = topTime;
	}
	public void setDeleted(boolean deleted) {
		this.deleted = deleted;
	}
}
